// ----------------------------------------------------------------------------
// serialize_pointer_member.h
// ----------------------------------------------------------------------------
#pragma once
#include <stddef.h>
#include <fw/base/serialize/serialize_member.h>
#include <fw/base/serialize/serialize_pointer_type.h>
#include <fw/base/runtime/hash.h>

namespace fw
{
	class SerializeSchema;
	class SerializeCompoundType;
	class SerializeAllocator;
	class ByteReader;
	class ByteWriter;
	
	class SerializePointerMember : public SerializeMember
	{
	private:
		const SerializeType*		m_type;
		
	public:
		SerializePointerMember(int count, Hash typeName);
		virtual ~SerializePointerMember();
		
		virtual size_t		GetSize		() const;
		virtual size_t		GetAlignment() const;
		virtual void		Convert		(char*					dstData,
										 const char*			srcData,
										 const SerializeMember&	srcMember,
										 SerializeAllocator&	alloc) const;
		virtual const SerializeType* PreFixUp(SerializeSchema& schema, Hash typeName);
		
	}; // class SerializePointerMember
	
} // namespace fw
